package com.obas.event {
   import com.ease.framework.CommandCompletionEvent;

   import flash.events.Event;

   [Response(name="{RETURN_ID}", type="com.ease.framework.CommandCompletionEvent")]
   public class TestPlanOperationEvent extends Event {

      public static const REQUEST_ID:String = "TestPlanOperationEvent_Request";

      public static const RETURN_ID:String = "TestPlanOperationEvent_Return";

      public static const GET_TEST_PLAN:int = 1;

      public static const CREATE_TEST_PLAN:int = 2;

      public static const GET_SYS_FUN:int = 3;

      public static const GET_TEST_ITEM:int = 4;

      public static const GET_TASK:int = 5;

      public static const GET_TASK_ITEM:int = 6;

      public static const RUN_TEST_PLAN:int = 7;

      public static const GET_PLAN_REPORT:int = 8;

      private var _actionType:int = GET_TEST_PLAN;

      private var _spec:Object=null;

      public function TestPlanOperationEvent(spec:Object, actionType:int = GET_TEST_PLAN, type:String=null) {
         var typeId:String = type;
         if (type == null) {
            typeId=REQUEST_ID;
         }
         super(typeId, true, true);
         _spec = spec;
         _actionType=actionType;
      }

      public override function clone():Event {
         var event:TestPlanOperationEvent=new TestPlanOperationEvent(spec, actionType, type);
         return event;
      }

      public function get spec():Object {
         return _spec;
      }

      public function get actionType():int {
         return _actionType;
      }
   }
}